package com.finalist.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.finalist.dao.EditorTemplateDao;
import com.finalist.entity.EditorTemplate;
import com.finalist.service.EditorTemplateService;

@Service("editorTemplateServiceImpl")
public class EditorTemplateServiceImpl extends BaseServiceImpl<EditorTemplate, Long> implements EditorTemplateService{

	@Resource(name = "editorTemplateDaoImpl")
	private EditorTemplateDao editorTemplateDao;
	
	@Resource(name = "editorTemplateDaoImpl")
	public void setBaseDao(EditorTemplateDao editorTemplateDao){
		super.setBaseDao(editorTemplateDao);
	}
	
	@Override
    @Transactional(readOnly = true)
    public boolean nameExists(String name)
    {
        return this.editorTemplateDao.nameExists(name);
    }
}
